import { applyMiddleware, createStore } from 'redux'
import { composeWithDevTools } from 'redux-devtools-extension'
import thunk from 'redux-thunk'
import rootReducer from './reduce/indedx'

const store = createStore(
  rootReducer,
  composeWithDevTools(applyMiddleware(thunk))
)
console.log(10, store)

export type AppDispatch = typeof store.dispatch
export type RootState = ReturnType<typeof store.getState>
export default store
